package com.foreknow.demo9Exercise7;

/**
 * 圆类
 */
public class Circle implements ShapePara{

    public double radius;
    private double x;
    private double y;

    public Circle() {

    }

    public double getRadius() {
        return radius;
    }

    public void setRadius(double radius) {
        this.radius = radius;
    }

    public void setCenter(double x, double y) {

    }

    //获得图形的面积
    @Override
    public void getArea() {
        double area = 0;
        area = 3.14*getRadius()*getRadius();
        System.out.println(area);
    }

    //获得图形的周长
    @Override
    public void getCircumference() {
    double cir = 0;
    cir = 3.14*2*getRadius();
        System.out.println(cir);
    }

    public static void main(String[] args) {
        Circle c = new Circle();
        c.setRadius(6);
        c.setCenter(3,4);
        c.getArea();
        c.getCircumference();
    }

}
